﻿using System;
using System.Collections.Generic;
using System.Text;

namespace KaiXin001er.UTIL
{
    public class RandomGen
    {
        public static  string 随机整数()
        {
            Random r = new Random();
            double d=r.NextDouble()*100000000;
            int i=(int)d;
            return i.ToString();
        }
        public static string 随机小数()
        {
            Random r = new Random();
            return r.NextDouble().ToString();
        }
        public static string 随即小数加日期()
        {
            Random radm = new Random();
            string randomstr = "" + radm.NextDouble() + "_";
            TimeSpan t = DateTime.Now - DateTime.Parse("1970-1-1 00:00:00");
            randomstr += "" + (long)t.TotalMilliseconds;
            return randomstr;
        }
    }
}
